home *** CD-ROM | disk | FTP | other *** search
/ Nebula 1 / Nebula One.iso / Communications / IBTip / Source / Modem.h < prev    next >
Encoding:
Text File  |  1995-06-12  |  977 b   |  36 lines

  1. #import "Tty.h"
  2.  
  3. enum protocol {xmodem, xmodem1k, ymodem, zmodem};
  4. enum direction {tohost, fromhost};
  5.  
  6. @interface Modem:Tty
  7. {
  8.   int capturefd;
  9.   enum protocol receiveProt, sendProt;
  10. }
  11.  
  12. + newA;    // will open serial port A
  13. + newB;    // will open serial port B
  14. + newPort:(char *)dev speed:(int)bps;
  15. - hangup;
  16. - forkExecArgv:(char **)argv;   // this is called by other methods
  17. - receiveZmodem;
  18. - sendZmodemFile:(char *)filename;
  19. - receiveYmodem;
  20. - sendYmodemFile:(char *)filename;
  21. - receiveXmodemFile:(char *)filename;
  22. - sendXmodemFile:(char *)filename;
  23. - receiveXmodem1kFile:(char *)filename;
  24. - sendXmodem1kFile:(char *)filename;
  25. - receive;
  26. - sendFile:(char *)filename;
  27. - setProtocol:(char)p dir:(enum direction)dir;
  28. - (int) getProtocolDir:(enum direction)dir;
  29. - captureSessionInFile:(char *)filename;
  30. - endCapture;
  31. - (BOOL) isCapturing;
  32. - (int) readInto:(char *)buf;  //returns number of characters read into buf
  33. - (int) writeOut:(char *)buf paced:(unsigned long)delay;
  34.  
  35. @end
  36.